package service;

import java.text.DecimalFormat;

/**
 * ClassName:Test
 * Package:service
 *
 * @date:2021/10/29 11:50 上午
 * @author: Tiangle
 */
public class Test {
    public static void main(String[] args) {
        System.out.println(moto(4));
    }
    public static double moto(int m){
        if (m>1){
            double i = 100.0 / m;
            System.out.println(i);
            return i+moto(m-1);
        }else{
            System.out.println(100);
            return 100;
        }
    }
}
